import type { AppRouteModule } from '@/router/types';

import { getParentLayout, LAYOUT } from '@/router/constant';
import { t } from '@/hooks/web/useI18n';

const checkin: AppRouteModule = {
  path: '/checkin', //router路径
  name: 'CheckIn', //router name
  component: LAYOUT, //体检登记
  redirect: '/checkin/checkinpage', //跳转路径
  meta: {
    orderNo: 3, //排序号，数字越靠前菜单考前
    icon: 'icon-park-outline:check-in', //icon图标
    title: t('routes.oper.checkin.checkin'), //标题，从locales/lang/zh-CN中找
  },
  children: [
    {
      path: 'checkinpage',
      name: 'CheckInPage',
      meta: {
        icon: 'icon-park-outline:check-in',
        title: t('routes.oper.checkin.checkin'),
      },
      component: () => import('@/views/peis/check-in/index.vue'),
    },
    {
      path: 'checkinadd',
      name: 'CheckInAdd',
      meta: {
        icon: 'ion:archive-outline',
        title: t('routes.oper.checkin.checkinadd'),
      },
      component: () => import('@/views/peis/check-in/add.vue'),
    },
  ],
};

export default checkin;
